﻿<%@ Page Language="C#" AutoEventWireup="true" MasterPageFile="~/Site.Master" CodeBehind="ViewSubject.aspx.cs" Inherits="SchoolAdministration.ViewSubject" %>
<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="server">
    <style type="text/css">
        .fieldvalidator
{padding-left:40px; color:red;
}
          .checkbox
          {margin-left:190px;
           padding-right:20px;
           float:left;
          }
        </style>
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="pagetitle" runat="server">
     <h3 class="page-title">
                    View Subject
                   </h3>
</asp:Content>
<asp:Content ID="Content3" ContentPlaceHolderID="breadcrum" runat="server">
        <ul class="breadcrumb">
                       <li>
                           <a href="#">School Administrator</a>
                           <span class="divider">/</span>
                       </li>
                       <li>
                           <a href="#">Routine Manangement</a>
                           <span class="divider">/</span>
                       </li>
                       <li class="active">
                          View Subjects
                       </li>
                      
                   </ul>
</asp:Content>
<asp:Content ID="Content4" ContentPlaceHolderID="mainchangingpart" runat="server">
  <div class="widget yellow">
      <div class="widget-title">
           <h4>View Subjects</h4>
      </div>
      <div class="widget-body">
          <asp:GridView ID="GridViewSubject" runat="server" AutoGenerateColumns="False" CssClass="table table-bordered"
               OnSelectedIndexChanged="GridViewSubject_SelectedIndexChanged"
               OnRowDataBound="GridViewSubject_RowDataBound"
               OnRowCommand="GridViewSubject_RowCommand"
               OnRowDeleted="GridViewSubject_RowDeleted"
               OnRowDeleting="GridViewSubject_RowDeleting">
                                <Columns>
                                    <asp:BoundField DataField="SubjectId" HeaderText="Id" SortExpression="SubjectId" />
                                    <asp:BoundField DataField="SubjectName" HeaderText="Subject Name" SortExpression="SubjectName" />
                                    <asp:BoundField DataField="SubjectCode" HeaderText="Subject Code" SortExpression="SubjectCode" />
                                    <asp:BoundField DataField="className" HeaderText="Grade" SortExpression="className" />
                                    <asp:TemplateField HeaderText="Edit">
                                        <ItemTemplate>
                                          <asp:HyperLink  runat="server" ID="BtnEdit" Text="Edit" NavigateUrl='<%# "EditSubject.aspx?SubjectId=" + Eval("SubjectId") + "&SubjectName=" + Eval("SubjectName") %>' />
                                          </ItemTemplate>
                                  </asp:TemplateField>
                                   <asp:TemplateField HeaderText="Delete">
                                        <ItemTemplate>
                                         <asp:LinkButton  ID="DeleteButton" CommandArgument='<%# Eval("SubjectId") %>' CommandName="Delete" runat="server">
                                            Delete</asp:LinkButton>
                                        </ItemTemplate>
                                  </asp:TemplateField>

                                </Columns>

          </asp:GridView>
      </div>
</div>
                    <!-- TEXTBOXES -->
      
 
</asp:Content>

